package CSDN;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 王圆豪
 * Date: 2025-04-28
 * Time: 22:57
 */
public class Test6 {
    public static void main(String[] args) throws InterruptedException {
        Thread thread = new Thread(()->{
            try {
                Thread.sleep(3000);
            } catch (InterruptedException e) {
                throw new RuntimeException(e);
            }
            System.out.println("thread线程结束！");
        });
        thread.start();
        thread.join();
        System.out.println("main线程结束！");
    }
}
